package com.controller;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import com.entity.Product;
import com.service.ProductService;
/**
 * 产品信息表
 * @author huyongzj
 *
 */
@Controller
public class ProductController {
	@Autowired
	private ProductService productService;
	/**
	 * 查询全部
	 */
	@RequestMapping("X-admin/jsp/getall_product.s")
	public String getAllProduct(Model model){
		List<Product> list= productService.selectByExample();
		model.addAttribute("list",list);
		return "X-admin/jsp/hy_product";
	}

}
